import { IParam } from '../../common';
import { IViewLogicInput } from '../../modules';
import { IDataViewCtrlAbility } from '../ability';
import { IDataViewCtrlStore } from '../store';
import { IMDCtrlController } from './i-md-ctrl-controller';

/**
 * 卡片视图部件控制器接口
 *
 * @export
 * @interface IDataViewCtrlController
 * @extends {ICtrlController}
 */
export interface IDataViewCtrlController<
	S extends IDataViewCtrlStore,
	A extends IDataViewCtrlAbility
> extends IMDCtrlController<S, A> {
	/**
	 * 处理项点击
	 *
	 * @param {IParam} item
	 * @param {MouseEvent} event
	 * @memberof IDataViewCtrlController
	 */
	handleItemClick(item: IParam, event: MouseEvent): void;

	/**
	 * 处理项双击
	 *
	 * @param {IParam} item
	 * @param {MouseEvent} event
	 * @memberof IDataViewCtrlController
	 */
	handleItemDbClick(item: IParam, event: MouseEvent): void;

	/**
	 * 加载更多
	 *
	 * @memberof IDataViewCtrlController
	 */
	loadMore(): void;
}
